package com.example.emos.wx.config.shiro;

import org.springframework.stereotype.Component;

/**
 * @program: emos-wx-api
 * @author: JackLiang
 * @create: 2021-03-29 23:07
 **/


@Component
public class ThreadLocalToken {
    private ThreadLocal local=new ThreadLocal();
    public  void setToken(String token){
        local.set(token);
    }

    public String getToken(){
        return (String)local.get();
    }
    public void clear(){
        local.remove();

    }
}
